#include "SDLProgressMonitor.h"

using namespace sdl;

SDLProgressMonitor::SDLProgressMonitor(void) : minimumProgress(0), maximumProgress(0), currentProgress(0)
{
}

SDLProgressMonitor::SDLProgressMonitor(int min, int max, int current) : minimumProgress(min), maximumProgress(max), currentProgress(current)
{
}

SDLProgressMonitor::~SDLProgressMonitor(void)
{
}

void SDLProgressMonitor::setMinimumProgress(int progress)
{
	minimumProgress = progress;
}

void SDLProgressMonitor::setMaximumProgress(int progress)
{
	maximumProgress = progress;
}

int SDLProgressMonitor::getMaximumProgress(void)
{
	return maximumProgress;
}

int SDLProgressMonitor::getProgress(void)
{
	return currentProgress;
}

void SDLProgressMonitor::update(Observable* observable)
{
	SDLTask* task = static_cast<SDLTask*>(observable);
	currentProgress = task->getProgress();
}
